﻿using Newtonsoft.Json;

namespace UmbracoExtending.District.Model
{
    /// <summary>
    /// 行政区域详细信息对象
    /// </summary>
    public class DistrictInfo
    {
        /// <summary>
        /// 省份编码
        /// </summary>
        public string ProvinceCode { get; set; }
        /// <summary>
        /// 省份名称
        /// </summary>
        public string ProvinceName { get; set; }

        /// <summary>
        /// 城市编码
        /// </summary>
        public string CityCode { get; set; }

        /// <summary>
        /// 城市名称
        /// </summary>
        public string CityName { get; set; }

        /// <summary>
        /// 区域编码
        /// </summary>
        public string DistrictCode { get; set; }

        /// <summary>
        /// 区域名称
        /// </summary>
        public string DistrictName { get; set; }

        /// <summary>
        /// 别名
        /// </summary>
        public string AliasName { get; set; }

        /// <summary>
        /// 重载输出字符串方法
        /// </summary>
        /// <returns>返回JSON类型字符串</returns>
        public override string ToString()
        {
            return JsonConvert.SerializeObject(this);
        }
    }
}
